<?php
// Identify the location of the application directory in respect to
// the bootstrap file's location, and configure PHP's include_path to
// include the library directory's location
define('ROOT_PATH', realpath(dirname(__FILE__)));
define('APPLICATION_PATH', realpath(ROOT_PATH . '/application'));
set_include_path( APPLICATION_PATH. '/../library'. PATH_SEPARATOR . get_include_path() );
set_include_path('application/models' . PATH_SEPARATOR . get_include_path());

// Give the Zend Framework the ability to load classes on demand,
// as you request them, rather than having to deal with require() statements.
require_once "Zend/Loader.php";
Zend_Loader::registerAutoload();

// Retrieve the bootstrap.php file
try {
    require 'application/bootstrap.php';
} catch (Exception $exception) {
    echo $exception->getMessage();
    exit(1);
}

// Start using the front controller in order to route URL requests
Zend_Controller_Front::getInstance()->dispatch();
?>
